/*
 * @Author: zhangyang
 * @Date: 2022-06-11 19:57:41
 * @LastEditTime: 2022-06-11 20:14:29
 * @Description: 
 */
const srcParse = (str) => {
  const menus = [];
  for (const tv of str.split('\n')) {
    const [name, url] = tv.split(',');
    name && url && menus.push({
      name,
      url
    });
  }
  return menus;
};

module.exports = srcParse;